﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Ventas.Master" AutoEventWireup="true" CodeBehind="CProveedor.aspx.cs" Inherits="Trade.WebForm7" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxEditors" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxGridView" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxPopupControl" tagprefix="dx" %><%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxEditors" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxGridView" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.v13.1, Version=13.1.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxPopupControl" tagprefix="dx" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<style type="text/css">
        .style1
        {
            width: 109px;
        }
</style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="div1"  style="position:absolute; height:490px;width:1000px;margin-top:6px;display:inline-table;border:1px solid #EF7F01;vertical-align:middle;left:50%;margin-left:-500px;">
        <table border="0" style="width:90%;margin-top:20px;margin-left:50px;">
            <tr>
                <td>
                    <table>
                    <tr>
                        <td class="style1">    
                            <dx:ASPxButton ID="btnAdd" runat="server" Text="Add Provider" 
                                Theme="SoftOrange1"   Width="100%" onclick="btnAdd_Click" >
                            </dx:ASPxButton>
                        </td>
                        <td>                     
                            <dx:ASPxButton ID="btnCancelar" runat="server" Text="Cancel" 
                                Theme="SoftOrange1" Width="10%" onclick="btnCancelar_Click">
                            </dx:ASPxButton>
                        </td>
                    </tr>
                    </table>
                </td>
                <td>
                    &nbsp;</td>
            </tr>
            <tr>
                <td>
                            
                    <dx:ASPxLabel ID="lblAddExito" runat="server" Text="Provider Added Successfully" Visible="false" ForeColor="Red" Font-Size="14px" Font-Bold="true"></dx:ASPxLabel>
                            
                </td>
            </tr>
            <tr>
                <td>   
                    <dx:ASPxGridView ID="dtg_Proveedores" runat="server" 
                        AutoGenerateColumns="False" EnableTheming="True" Theme="Metropolis1">
                        <Columns>
                            <dx:GridViewCommandColumn VisibleIndex="0" Visible="False" 
                                ShowSelectCheckbox="True">
                                <ClearFilterButton Visible="True">
                                </ClearFilterButton>
                            </dx:GridViewCommandColumn>
                                <dx:GridViewDataTextColumn Caption="Code" FieldName="Codigo" VisibleIndex="1" Visible="false"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Name" FieldName="Nombre" VisibleIndex="2"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Telephone" FieldName="Telefono" VisibleIndex="3"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Mail" FieldName="Correo" VisibleIndex="4"></dx:GridViewDataTextColumn>
                        </Columns>
                        <Settings ShowFilterRow="True" />
                    </dx:ASPxGridView>
                            
                </td>
            </tr>
            <tr>
                <td>  
                    <dx:ASPxPopupControl ID="Popup_Buscar_Proveedor" runat="server" RenderMode="Lightweight"
                    HeaderText="Select Provider" Modal="true" PopupHorizontalAlign="WindowCenter"
                    PopupVerticalAlign="WindowCenter" Theme="SoftOrange1" EnableTheming="true">
                        <ContentCollection>
                            <dx:PopupControlContentControl>
                                    <div id="recuadro_inicio" style="width:450px;margin-left:auto;margin-right:auto;margin-top:10px;overflow:hidden;height:auto;background-color:#FFF;border:2px solid #B74900;">
                                        <dx:ASPxGridView ID="dtgProveedores" runat="server" Theme="SoftOrange1" 
                                            AutoGenerateColumns="false" KeyFieldName="Codigo" >
                                            <ClientSideEvents RowDblClick="function(s, e) {
                                                                                            var key = s.GetRowKey(e.visibleIndex);
                                                                                            window.location.href='CProveedor.aspx?prov='+key;
                                                                                        }" />
                                            <Columns>
                                                <dx:GridViewCommandColumn ShowInCustomizationForm="True" VisibleIndex="0" 
                                                    Visible="False">
                                                    <ClearFilterButton Visible="True">
                                                    </ClearFilterButton>
                                                </dx:GridViewCommandColumn>
                                                <dx:GridViewDataTextColumn Caption="Code" FieldName="Codigo" VisibleIndex="1" 
                                                    Visible="False"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Name" FieldName="Nombre" VisibleIndex="2"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Telephone" FieldName="Telefono" VisibleIndex="3"></dx:GridViewDataTextColumn>
                                                <dx:GridViewDataTextColumn Caption="Mail" FieldName="Correo" VisibleIndex="4"></dx:GridViewDataTextColumn>
                                            </Columns>
                                            <SettingsBehavior AllowFocusedRow="true"/>
                                            <Settings ShowFilterRow="True" ShowGroupPanel="True" />
                                            <SettingsBehavior AllowFocusedRow="True"></SettingsBehavior>
                                            <Settings ShowFilterRow="True" ShowGroupPanel="True"></Settings>
                                        </dx:ASPxGridView>
                                </div>
                            </dx:PopupControlContentControl>
                        </ContentCollection>
                    </dx:ASPxPopupControl>
                </td>
            </tr>
            <tr>
                <td></td>
            </tr>
            <tr>
                <td></td>
            </tr>
        </table>  
    </div>
</asp:Content>
